#!/bin/bash

SQL_PATH=`dirname $0`/sql

if [ $# -ne 3 ]; then
   echo "Usage: $0 <trace_sq3_file> <csv_output_file> <query_name>"
   exit 2
fi

sqlite3 -header -separator ',' "$1" < $SQL_PATH/$3.sql > "$2"
